class Solution {
public:
    int smallestRangeI(vector<int>& nums, int k) {
        int mmin = 10000000,mmax = 0;
        for(auto e :nums){
            if(e > mmax) mmax = e;
            if(e < mmin) mmin = e;
        }
        cout << mmax <<' '<<mmin;
        return max(0,mmax - mmin - 2* k);
    }
};